﻿<ResourceDictionary
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" 
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:c4fConverters="using:Coding4Fun.Toolkit.Controls.Converters"
    xmlns:Binding="clr-namespace:Coding4Fun.Toolkit.Controls.Binding"
    xmlns:local="using:Coding4Fun.Toolkit.Controls">

    <c4fConverters:SolidColorBrushToColorConverter x:Key="BrushToBrush" />
    <SolidColorBrush x:Key="DefaultAccentBrush" Color="{Binding Source={StaticResource PhoneAccentBrush}, Converter={StaticResource BrushToBrush}}" />
    <SolidColorBrush x:Key="DefaultChromeBrush" Color="{Binding Source={StaticResource PhoneChromeBrush}, Converter={StaticResource BrushToBrush}}" />
    <SolidColorBrush x:Key="DefaultBackgroundBrush" Color="{Binding Source={StaticResource PhoneBackgroundBrush}, Converter={StaticResource BrushToBrush}}" />
    <SolidColorBrush x:Key="DefaultForegroundBrush" Color="{Binding Source={StaticResource PhoneForegroundBrush}, Converter={StaticResource BrushToBrush}}" />
    <SolidColorBrush x:Key="DefaultSubtleBrush" Color="#99FFFFFF" />
    <SolidColorBrush x:Key="DefaultDisabledBrush" Color="{Binding Source={StaticResource PhoneDisabledBrush}, Converter={StaticResource BrushToBrush}}" />
    <SolidColorBrush x:Key="DefaultContrastDisabledBrush" Color="{Binding Source={StaticResource PhoneChromeBrush}, Converter={StaticResource BrushToBrush}}" />
    <SolidColorBrush x:Key="DefaultSemiTransparentBrush" Color="{Binding Source={StaticResource PhoneBackgroundBrush}, Converter={StaticResource BrushToBrush}, ConverterParameter=99}" />

    <x:Double x:Key="DefaultFontSizeExtraSmall">12</x:Double>
    <x:Double x:Key="DefaultFontSizeSmall">16</x:Double>
    <x:Double x:Key="DefaultFontSizeNormal">20</x:Double>
    <x:Double x:Key="DefaultFontSizeMedium">22.667</x:Double>
    <x:Double x:Key="DefaultFontSizeMediumLarge">25.333</x:Double>
    <x:Double x:Key="DefaultFontSizeLarge">32</x:Double>
    <FontFamily x:Key="FontFamilySegoeNormal">Segoe WP</FontFamily>
    <FontFamily x:Key="FontFamilySegoeSemiBold">Segoe WP Semibold</FontFamily>
    <FontFamily x:Key="FontFamilySegoeSemiLight">Segoe WP SemiLight</FontFamily>
    <x:Double x:Key="DefaultAppButtonSize">70</x:Double>
    <x:Double x:Key="DefaultTileSize">173</x:Double>
    <Thickness x:Key="DefaultTextBoxInnerMargin">1,2</Thickness>
    <Thickness x:Key="DefaultBorderThickness">3</Thickness>

    <SolidColorBrush x:Key="DefaultTextBoxBrush" Color="{Binding Source={StaticResource TextBoxBackgroundThemeBrush}, Converter={StaticResource BrushToBrush}}" />
    <SolidColorBrush x:Key="DefaultTextBoxForegroundBrush" Color="{Binding Source={StaticResource TextBoxForegroundThemeBrush}, Converter={StaticResource BrushToBrush}}" />
    <SolidColorBrush x:Key="DefaultTextBoxReadOnlyBrush" Color="{Binding Source={StaticResource DefaultSubtleBrush}, Converter={StaticResource BrushToBrush}}" />
    <SolidColorBrush x:Key="DefaultTextBoxEditBackgroundBrush" Color="{Binding Source={StaticResource DefaultChromeBrush}, Converter={StaticResource BrushToBrush}}" />
    <SolidColorBrush x:Key="DefaultTextBoxEditBorderBrush" Color="{Binding Source={StaticResource DefaultAccentBrush}, Converter={StaticResource BrushToBrush}}" />

    <Style TargetType="local:ProgressOverlay">
        <Setter Property="Background" Value="{StaticResource DefaultSemiTransparentBrush}"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="local:ProgressOverlay">
                    <Grid 
                        Background="{TemplateBinding Background}"
                        Name="LayoutGrid" 
                        HorizontalAlignment="Stretch"
                        VerticalAlignment="Stretch">
                        <Grid.Resources>
                            <Storyboard x:Key="fadeOut" x:Name="FadeOutStoryboard">
                                <DoubleAnimation Duration="0:0:0.5" To="0" Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="LayoutGrid" />
                            </Storyboard>
                            <Storyboard x:Key="fadeIn" x:Name="FadeInStoryboard">
                                <DoubleAnimation Duration="0:0:0.5" From="0" To="1" Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="LayoutGrid" />
                            </Storyboard>
                        </Grid.Resources>
                        <Rectangle Fill="Transparent" />
                        <Grid>
                            <ContentControl Content="{TemplateBinding Content}" HorizontalContentAlignment="Stretch" />
                        </Grid>
                    </Grid>
                </ControlTemplate>

            </Setter.Value>
        </Setter>
    </Style>
    
    <Style TargetType="local:ColorPicker">
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="local:ColorPicker">
                    <Grid>
                        <VisualStateManager.VisualStateGroups>
                            <VisualStateGroup x:Name="CommonStates">
                                <VisualState x:Name="Normal" />
                                <VisualState x:Name="Disabled">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames
                                            Storyboard.TargetProperty="Opacity" 
											Storyboard.TargetName="SelectedHueColor">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="0"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames
                                            Storyboard.TargetProperty="Opacity" 
											Storyboard.TargetName="SampleSelector">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="0"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames
                                            Storyboard.TargetProperty="Fill" 
											Storyboard.TargetName="SelectedColor">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource DefaultDisabledBrush}"/>
                                        </ObjectAnimationUsingKeyFrames>

                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                        </VisualStateManager.VisualStateGroups>
                        <Grid.ColumnDefinitions>
                            <ColumnDefinition Width="Auto" />
                            <ColumnDefinition Width="*" />
                        </Grid.ColumnDefinitions>
                        <Grid.RowDefinitions>
                            <RowDefinition Height="Auto" />
                            <RowDefinition Height="*" />
                        </Grid.RowDefinitions>

                        <Rectangle 
                            Margin="0,0,0,12"
                            Height="24"
			                Grid.Row="0"
                            Grid.ColumnSpan="2"
							Name="SelectedColor"
			                Fill="{TemplateBinding SolidColorBrush}" />

                        <local:ColorSlider 
                            Width="24"
                            Margin="0,0,12,0"
                            IsColorVisible="false" 
                            Thumb="{TemplateBinding Thumb}"
                            x:Name="ColorSlider" 
                            Grid.Row="2"/>

                        <Grid 
                            Name="Body"
			                Grid.Column="1"
			                Grid.Row="1">
                            <Rectangle 
                                Name="SelectedHueColor" 
                                Fill="Red" />
                            <Rectangle>
                                <Rectangle.Fill>
                                    <LinearGradientBrush StartPoint="0,0" EndPoint="1,0">
                                        <GradientStop Offset="0" Color="White"/>
                                        <GradientStop Offset="1" Color="Transparent"/>
                                    </LinearGradientBrush>
                                </Rectangle.Fill>
                            </Rectangle>
                            <Rectangle>
                                <Rectangle.Fill>
                                    <LinearGradientBrush StartPoint="0,1" EndPoint="0, 0">
                                        <GradientStop Offset="0" Color="Black"/>
                                        <GradientStop Offset="1" Color="Transparent"/>
                                    </LinearGradientBrush>
                                </Rectangle.Fill>
                            </Rectangle>
                            <Grid 
                                Name="SampleSelector"
                                VerticalAlignment="Top" 
                                HorizontalAlignment="Left">
                                <Ellipse
                                    Height="22"
                                    Width="22"
                                    StrokeThickness="5" 
                                    Stroke="Black" />
                                <Ellipse 
                                    Height="24"
                                    Width="24"
                                    StrokeThickness="3" 
                                    Stroke="White" />
                            </Grid>
                        </Grid>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    
    <Style TargetType="local:ColorSliderThumb">
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="local:ColorSliderThumb">
                    <Grid>
                        <Rectangle 
				            Stroke="Black"
                            StrokeThickness="6" />
                        <Rectangle 
				            Stroke="White"
                            StrokeThickness="3" />
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <Style x:Key="ColorSliderSuperSlider" TargetType="local:SuperSlider">
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="local:SuperSlider">
                    <Grid 
                        x:Name="Body">

                        <VisualStateManager.VisualStateGroups>
                            <VisualStateGroup x:Name="CommonStates">
                                <VisualState x:Name="Normal" />
                                <VisualState x:Name="Disabled">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames
											Storyboard.TargetProperty="Visibility" 
											Storyboard.TargetName="IsEnabledRectangle">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames
											Storyboard.TargetProperty="Fill" 
											Storyboard.TargetName="IsEnabledRectangle">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource DefaultChromeBrush}"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames
											Storyboard.TargetProperty="Opacity" 
											Storyboard.TargetName="IsEnabledRectangle">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value=".5"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames
                                            Storyboard.TargetProperty="Opacity" 
											Storyboard.TargetName="ThumbContentPresenter">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value=".75"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                        </VisualStateManager.VisualStateGroups>

                        <Rectangle 
							x:Name="BackgroundRectangle"
							Fill="{TemplateBinding Background}" />
                        <Rectangle 
							x:Name="ProgressRectangle"
							Fill="{TemplateBinding Foreground}" />
                        <Rectangle 
							x:Name="IsEnabledRectangle"
                            Visibility="Collapsed"/>
                        <ContentPresenter
							Grid.Row="1"
                            x:Name="ThumbContentPresenter"
							Content="{TemplateBinding Thumb}" />
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <Style TargetType="local:ColorSlider">
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="local:ColorSlider">
                    <Grid Name="Body">
                        <VisualStateManager.VisualStateGroups>
                            <VisualStateGroup x:Name="CommonStates">
                                <VisualState x:Name="Normal" />
                                <VisualState x:Name="Disabled">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames
													Storyboard.TargetProperty="Fill" 
													Storyboard.TargetName="SelectedColor">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource DefaultDisabledBrush}"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                        </VisualStateManager.VisualStateGroups>
                        <Rectangle 
                            Name="SelectedColor" 
                            Fill="{TemplateBinding SolidColorBrush}" />

                        <local:SuperSlider 
                            x:Name="Slider"
                            Orientation="{TemplateBinding Orientation}"
                            Foreground="Transparent"
                            Minimum="0"
                            Maximum="360" 
                            Thumb="{TemplateBinding Thumb}"
                            Style="{StaticResource ColorSliderSuperSlider}">
                        </local:SuperSlider>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <Style x:Key="MetroFlowItemTextBlockStyle" TargetType="TextBlock">
        <Setter Property="FontSize" Value="{StaticResource DefaultFontSizeMediumLarge}" />
        <Setter Property="Margin" Value="12, 3, 0, 3" />
        <Setter Property="HorizontalAlignment" Value="Left" />
        <Setter Property="VerticalAlignment" Value="Bottom" />
    </Style>
    <Style x:Key="MetroFlowItemRectangleUnderlay" TargetType="Rectangle">
        <Setter Property="Fill" Value="{StaticResource DefaultChromeBrush}" />
        <Setter Property="Margin" Value="0, -.5" />
        <Setter Property="Opacity" Value=".8" />
    </Style>
    <Style x:Key="MetroFlowItemImage" TargetType="Image">
        <Setter Property="Margin" Value="0, -.5, 0, 0" />
        <Setter Property="Stretch" Value="UniformToFill" />
        <Setter Property="HorizontalAlignment" Value="Center" />
        <Setter Property="VerticalAlignment" Value="Center" />
    </Style>
    <Style x:Key="MetroFlowItemMainBody" TargetType="Panel">
        <Setter Property="Background" Value="{StaticResource DefaultChromeBrush}" />
        <Setter Property="Margin" Value="6, 0" />
    </Style>
    <Style TargetType="local:MetroFlowItem">
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="local:MetroFlowItem">
                    <Grid>
                        <Grid Style="{StaticResource MetroFlowItemMainBody}">
                            <Rectangle Fill="{StaticResource DefaultAccentBrush}" />
                            <Image Source="{TemplateBinding ImageSource}" Visibility="{TemplateBinding ImageVisibility}" Opacity="{TemplateBinding ImageOpacity}" Style="{StaticResource MetroFlowItemImage}" />
                            <Grid VerticalAlignment="Bottom">
                                <Rectangle Style="{StaticResource MetroFlowItemRectangleUnderlay}" />
                                <TextBlock Text="{TemplateBinding Title}" Visibility="{TemplateBinding TitleVisibility}" Opacity="{TemplateBinding TitleOpacity}" Style="{StaticResource MetroFlowItemTextBlockStyle}" />
                                <TextBlock Text="{TemplateBinding ItemIndexString}" Visibility="{TemplateBinding ItemIndexVisibility}" Opacity="{TemplateBinding ItemIndexOpacity}" Style="{StaticResource MetroFlowItemTextBlockStyle}" />
                            </Grid>
                        </Grid>
                        <Rectangle Fill="Transparent" />
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    <Style TargetType="local:MetroFlow">
        <Setter Property="Height" Value="120" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="local:MetroFlow">
                    <Grid Name="LayoutRoot">
                        <local:MetroFlowItem Title="MetroFlow Control" />
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <ControlTemplate x:Key="DisabledChatBubbleTextBoxTemplate" TargetType="TextBox">
        <ContentControl x:Name="ContentElement" BorderThickness="0" Margin="{TemplateBinding Margin}" HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}" Padding="{TemplateBinding Padding}" VerticalContentAlignment="{TemplateBinding VerticalContentAlignment}" />
    </ControlTemplate>

    <Style x:Key="AppBarText" TargetType="ContentControl">
        <Setter Property="HorizontalAlignment" Value="Center" />
        <Setter Property="Margin" Value="0" />
    </Style>

    <Style TargetType="local:OpacityToggleButton">
        <Setter Property="Foreground" Value="{StaticResource DefaultForegroundBrush}" />
        <Setter Property="Background" Value="{StaticResource DefaultForegroundBrush}" />
        <Setter Property="FontFamily" Value="{StaticResource FontFamilySegoeSemiBold}" />
        <Setter Property="FontSize" Value="{StaticResource DefaultFontSizeExtraSmall}" />
        <Setter Property="ButtonWidth" Value="{StaticResource DefaultAppButtonSize}" />
        <Setter Property="ButtonHeight" Value="{StaticResource DefaultAppButtonSize}" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="local:OpacityToggleButton">
                    <Grid>
                        <VisualStateManager.VisualStateGroups>
                            <VisualStateGroup x:Name="CheckStates">
                                <VisualState x:Name="Checked">
                                    <Storyboard>
                                        <DoubleAnimation Duration="{Binding AnimationDuration, RelativeSource={RelativeSource TemplatedParent}}" To="{Binding CheckedOpacity, RelativeSource={RelativeSource TemplatedParent}}" Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="ContentHost" />
                                        <DoubleAnimation Duration="{Binding AnimationDuration, RelativeSource={RelativeSource TemplatedParent}}" To="{Binding CheckedOpacity, RelativeSource={RelativeSource TemplatedParent}}" Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="DisabledContentHost" />
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="Unchecked">
                                    <Storyboard>
                                        <DoubleAnimation Duration="{Binding AnimationDuration, RelativeSource={RelativeSource TemplatedParent}}" To="{Binding UncheckedOpacity, RelativeSource={RelativeSource TemplatedParent}}" Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="ContentHost" />
                                        <DoubleAnimation Duration="{Binding AnimationDuration, RelativeSource={RelativeSource TemplatedParent}}" To="{Binding UncheckedOpacity, RelativeSource={RelativeSource TemplatedParent}}" Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="DisabledContentHost" />
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="Indeterminate" />
                            </VisualStateGroup>
                            <VisualStateGroup x:Name="CommonStates">
                                <VisualState x:Name="Normal" />
                                <VisualState x:Name="Disabled">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Visibility" Storyboard.TargetName="EnabledBackground">
                                            <DiscreteObjectKeyFrame KeyTime="0">
                                                <DiscreteObjectKeyFrame.Value>
                                                    <Visibility>Collapsed</Visibility>
                                                </DiscreteObjectKeyFrame.Value>
                                            </DiscreteObjectKeyFrame>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Visibility" Storyboard.TargetName="DisabledBackground">
                                            <DiscreteObjectKeyFrame KeyTime="0">
                                                <DiscreteObjectKeyFrame.Value>
                                                    <Visibility>Visible</Visibility>
                                                </DiscreteObjectKeyFrame.Value>
                                            </DiscreteObjectKeyFrame>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                        </VisualStateManager.VisualStateGroups>
                        <Border Name="EnabledBackground" Height="{TemplateBinding Height}" Width="{TemplateBinding Width}" Padding="{TemplateBinding Padding}" BorderThickness="0" BorderBrush="Transparent" Background="Transparent">
                            <StackPanel Orientation="{TemplateBinding Orientation}">
                                <Grid Width="{TemplateBinding ButtonWidth}" Height="{TemplateBinding ButtonHeight}" Margin="0,-10, 0, 0">
                                    <Grid Name="ContentHost">
                                        <ContentControl Name="EnabledContent" Foreground="{TemplateBinding Background}" HorizontalContentAlignment="Center" VerticalContentAlignment="Center">
                                            <Grid Name="EnabledHolder">
                                                <ContentControl Name="ContentBody" Content="{TemplateBinding Content}" />
                                            </Grid>
                                        </ContentControl>
                                    </Grid>
                                </Grid>
                                <ContentControl Name="ContentTitle" Margin="0, -5, 0 , 0" Content="{TemplateBinding Label}" Foreground="{TemplateBinding Foreground}" HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}" VerticalContentAlignment="{TemplateBinding VerticalContentAlignment}" Style="{StaticResource AppBarText}" />
                            </StackPanel>
                        </Border>
                        <Border Name="DisabledBackground" Height="{TemplateBinding Height}" Width="{TemplateBinding Width}" Padding="{TemplateBinding Padding}" BorderThickness="0" BorderBrush="Transparent" Background="Transparent" Visibility="Collapsed">
                            <StackPanel Orientation="{TemplateBinding Orientation}">
                                <Grid Width="{TemplateBinding ButtonWidth}" Height="{TemplateBinding ButtonHeight}" Margin="0,-10, 0, 0">
                                    <Grid Name="DisabledContentHost">
                                        <ContentControl Name="DisabledContent" Foreground="{StaticResource DefaultDisabledBrush}" HorizontalContentAlignment="Center" VerticalContentAlignment="Center">
                                            <Grid Name="DisabledHolder" />
                                        </ContentControl>
                                    </Grid>
                                </Grid>
                                <ContentControl Content="{TemplateBinding Label}" Foreground="{StaticResource DefaultDisabledBrush}" HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}" VerticalContentAlignment="{TemplateBinding VerticalContentAlignment}" Margin="{Binding Margin, ElementName=ContentTitle}" Style="{StaticResource AppBarText}" />
                            </StackPanel>
                        </Border>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <Style TargetType="local:RoundButton">
        <Setter Property="BorderBrush" Value="{StaticResource DefaultForegroundBrush}" />
        <Setter Property="Foreground" Value="{StaticResource DefaultForegroundBrush}" />
        <Setter Property="FontFamily" Value="{StaticResource FontFamilySegoeSemiBold}" />
        <Setter Property="PressedBrush" Value="{StaticResource DefaultAccentBrush}" />
        <Setter Property="FontSize" Value="{StaticResource DefaultFontSizeExtraSmall}" />
        <Setter Property="ButtonWidth" Value="{StaticResource DefaultAppButtonSize}" />
        <Setter Property="ButtonHeight" Value="{StaticResource DefaultAppButtonSize}" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="local:RoundButton">
                    <Grid>
                        <VisualStateManager.VisualStateGroups>
                            <VisualStateGroup x:Name="CommonStates">
                                <VisualState x:Name="Normal" />
                                <VisualState x:Name="MouseOver" />
                                <VisualState x:Name="Pressed">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Fill" Storyboard.TargetName="ButtonBackground">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{Binding PressedBrush, RelativeSource={RelativeSource TemplatedParent}}" />
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="Disabled">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Stroke" Storyboard.TargetName="ButtonRing">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource DefaultDisabledBrush}" />
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Fill" Storyboard.TargetName="ButtonBackground">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Transparent" />
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Foreground" Storyboard.TargetName="ContentBody">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource DefaultDisabledBrush}" />
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Foreground" Storyboard.TargetName="ContentTitle">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource DefaultDisabledBrush}" />
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                        </VisualStateManager.VisualStateGroups>
                        <Border Name="EnabledBackground" Padding="{TemplateBinding Padding}" BorderThickness="0" BorderBrush="Transparent" Background="Transparent">
                            <StackPanel Orientation="{TemplateBinding Orientation}">
                                <Grid Width="{TemplateBinding ButtonWidth}" Height="{TemplateBinding ButtonHeight}" Margin="0,-10, 0, 0">
                                    <Ellipse x:Name="ButtonBackground" Stroke="Transparent" Fill="{TemplateBinding Background}" Margin="10" />
                                    <Grid Name="ContentHost">
                                        <ContentControl Name="ContentBody" Content="{TemplateBinding Content}" Foreground="{TemplateBinding Foreground}" HorizontalContentAlignment="Center" VerticalContentAlignment="Center" />
                                    </Grid>
                                    <Ellipse x:Name="ButtonRing" Stroke="{TemplateBinding BorderBrush}" StrokeThickness="3" Fill="Transparent" Margin="10" />
                                </Grid>
                                <ContentControl x:Name="ContentTitle" Content="{TemplateBinding Label}" Foreground="{TemplateBinding Foreground}" HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}" VerticalContentAlignment="{TemplateBinding VerticalContentAlignment}" Style="{StaticResource AppBarText}" />
                            </StackPanel>
                        </Border>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    <Style TargetType="local:RoundToggleButton">
        <Setter Property="BorderBrush" Value="{StaticResource DefaultForegroundBrush}" />
        <Setter Property="Foreground" Value="{StaticResource DefaultForegroundBrush}" />
        <Setter Property="FontFamily" Value="{StaticResource FontFamilySegoeSemiBold}" />
        <Setter Property="CheckedBrush" Value="{StaticResource DefaultAccentBrush}" />
        <Setter Property="FontSize" Value="{StaticResource DefaultFontSizeExtraSmall}" />
        <Setter Property="ButtonWidth" Value="{StaticResource DefaultAppButtonSize}" />
        <Setter Property="ButtonHeight" Value="{StaticResource DefaultAppButtonSize}" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="local:RoundToggleButton">
                    <Grid>
                        <VisualStateManager.VisualStateGroups>
                            <VisualStateGroup x:Name="CheckStates">
                                <VisualState x:Name="Checked">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Fill" Storyboard.TargetName="ButtonBackground">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{Binding CheckedBrush, RelativeSource={RelativeSource TemplatedParent}}" />
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Fill" Storyboard.TargetName="DisabledButtonBackground">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource DefaultDisabledBrush}" />
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="StrokeThickness" Storyboard.TargetName="DisabledButtonRing">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="0" />
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Foreground" Storyboard.TargetName="DisabledContent">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource DefaultContrastDisabledBrush}" />
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="Unchecked" />
                                <VisualState x:Name="Indeterminate" />
                            </VisualStateGroup>
                            <VisualStateGroup x:Name="CommonStates">
                                <VisualState x:Name="Normal" />
                                <VisualState x:Name="Disabled">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Visibility" Storyboard.TargetName="EnabledBackground">
                                            <DiscreteObjectKeyFrame KeyTime="0">
                                                <DiscreteObjectKeyFrame.Value>
                                                    <Visibility>Collapsed</Visibility>
                                                </DiscreteObjectKeyFrame.Value>
                                            </DiscreteObjectKeyFrame>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Visibility" Storyboard.TargetName="DisabledBackground">
                                            <DiscreteObjectKeyFrame KeyTime="0">
                                                <DiscreteObjectKeyFrame.Value>
                                                    <Visibility>Visible</Visibility>
                                                </DiscreteObjectKeyFrame.Value>
                                            </DiscreteObjectKeyFrame>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                        </VisualStateManager.VisualStateGroups>
                        <Border Name="EnabledBackground" Height="{TemplateBinding Height}" Width="{TemplateBinding Width}" Padding="{TemplateBinding Padding}" BorderThickness="0" BorderBrush="Transparent" Background="Transparent">
                            <StackPanel Orientation="{TemplateBinding Orientation}">
                                <Grid Width="{TemplateBinding ButtonWidth}" Height="{TemplateBinding ButtonHeight}" Margin="0,-10, 0, 0">
                                    <Ellipse x:Name="ButtonBackground" Stroke="Transparent" Fill="{TemplateBinding Background}" Margin="10" />
                                    <Grid Name="ContentHost">
                                        <ContentControl Name="EnabledContent" Foreground="{TemplateBinding Foreground}" HorizontalContentAlignment="Center" VerticalContentAlignment="Center">
                                            <Grid Name="EnabledHolder">
                                                <ContentControl Name="ContentBody" Content="{TemplateBinding Content}" />
                                            </Grid>
                                        </ContentControl>
                                    </Grid>
                                    <Ellipse x:Name="ButtonRing" Stroke="{TemplateBinding BorderBrush}" StrokeThickness="3" Fill="Transparent" Margin="10" />
                                </Grid>
                                <ContentControl Name="ContentTitle" Margin="0, -5, 0 , 0" Content="{TemplateBinding Label}" Foreground="{TemplateBinding Foreground}" HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}" VerticalContentAlignment="{TemplateBinding VerticalContentAlignment}" Style="{StaticResource AppBarText}" />
                            </StackPanel>
                        </Border>
                        <Border Name="DisabledBackground" Height="{TemplateBinding Height}" Width="{TemplateBinding Width}" Padding="{TemplateBinding Padding}" BorderThickness="0" BorderBrush="Transparent" Background="Transparent" Visibility="Collapsed">
                            <StackPanel Orientation="{TemplateBinding Orientation}">
                                <Grid Width="{TemplateBinding ButtonWidth}" Height="{TemplateBinding ButtonHeight}" Margin="0,-10, 0, 0">
                                    <Ellipse x:Name="DisabledButtonBackground" Stroke="Transparent" Margin="10" />
                                    <Grid Name="DisabledContentHost">
                                        <ContentControl Name="DisabledContent" Foreground="{StaticResource DefaultDisabledBrush}" HorizontalContentAlignment="Center" VerticalContentAlignment="Center">
                                            <Grid Name="DisabledHolder" />
                                        </ContentControl>
                                    </Grid>
                                    <Ellipse x:Name="DisabledButtonRing" Stroke="{StaticResource DefaultDisabledBrush}" StrokeThickness="3" Fill="Transparent" Margin="10" />
                                </Grid>
                                <ContentControl Content="{TemplateBinding Label}" Foreground="{StaticResource DefaultDisabledBrush}" HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}" VerticalContentAlignment="{TemplateBinding VerticalContentAlignment}" Margin="{Binding Margin, ElementName=ContentTitle}" Style="{StaticResource AppBarText}" />
                            </StackPanel>
                        </Border>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <Style TargetType="local:ChatBubble">
        <Setter Property="Background" Value="{StaticResource DefaultAccentBrush}" />
        <Setter Property="FontFamily" Value="{StaticResource FontFamilySegoeNormal}" />
        <Setter Property="FontSize" Value="{StaticResource DefaultFontSizeMediumLarge}" />
        <Setter Property="BorderBrush" Value="{StaticResource DefaultAccentBrush}" />
        <Setter Property="BorderThickness" Value="{StaticResource DefaultBorderThickness}" />
        <Setter Property="Padding" Value="6, 2" />
        <Setter Property="HorizontalContentAlignment" Value="Left" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="local:ChatBubble">
                    <Grid Background="Transparent">
                        <VisualStateManager.VisualStateGroups>
                            <VisualStateGroup x:Name="CommonStates">
                                <VisualState x:Name="Normal" />
                                <VisualState x:Name="MouseOver" />
                                <VisualState x:Name="Disabled">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Background" Storyboard.TargetName="ContentBorder">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource DefaultDisabledBrush}" />
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="BorderBrush" Storyboard.TargetName="ContentBorder">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource DefaultDisabledBrush}" />
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Fill" Storyboard.TargetName="LowerRightPath">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource DefaultDisabledBrush}" />
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Fill" Storyboard.TargetName="LowerLeftPath">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource DefaultDisabledBrush}" />
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Fill" Storyboard.TargetName="UpperRightPath">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource DefaultDisabledBrush}" />
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Fill" Storyboard.TargetName="UpperLeftPath">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource DefaultDisabledBrush}" />
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                            <VisualStateGroup x:Name="ChatBubbleDirectionStates">
                                <VisualState x:Name="UpperRight">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Visibility" Storyboard.TargetName="UpperRightPath">
                                            <DiscreteObjectKeyFrame KeyTime="0">
                                                <DiscreteObjectKeyFrame.Value>
                                                    <Visibility>Visible</Visibility>
                                                </DiscreteObjectKeyFrame.Value>
                                            </DiscreteObjectKeyFrame>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="UpperLeft">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Visibility" Storyboard.TargetName="UpperLeftPath">
                                            <DiscreteObjectKeyFrame KeyTime="0">
                                                <DiscreteObjectKeyFrame.Value>
                                                    <Visibility>Visible</Visibility>
                                                </DiscreteObjectKeyFrame.Value>
                                            </DiscreteObjectKeyFrame>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="LowerRight">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Visibility" Storyboard.TargetName="LowerRightPath">
                                            <DiscreteObjectKeyFrame KeyTime="0">
                                                <DiscreteObjectKeyFrame.Value>
                                                    <Visibility>Visible</Visibility>
                                                </DiscreteObjectKeyFrame.Value>
                                            </DiscreteObjectKeyFrame>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="LowerLeft">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Visibility" Storyboard.TargetName="LowerLeftPath">
                                            <DiscreteObjectKeyFrame KeyTime="0">
                                                <DiscreteObjectKeyFrame.Value>
                                                    <Visibility>Visible</Visibility>
                                                </DiscreteObjectKeyFrame.Value>
                                            </DiscreteObjectKeyFrame>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                        </VisualStateManager.VisualStateGroups>
                        <Grid.RowDefinitions>
                            <RowDefinition Height="Auto" />
                            <RowDefinition Height="Auto" />
                            <RowDefinition Height="Auto" />
                        </Grid.RowDefinitions>
                        <Border x:Name="ContentBorder" Grid.Row="1" Padding="{TemplateBinding Padding}" BorderThickness="{TemplateBinding BorderThickness}" BorderBrush="{TemplateBinding BorderBrush}" Background="{TemplateBinding Background}">
                            <ContentControl HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}" Margin="{StaticResource DefaultTextBoxInnerMargin}" Content="{TemplateBinding Content}" FontSize="{TemplateBinding FontSize}" FontFamily="{TemplateBinding FontFamily}" />
                        </Border>
                        <Path Name="LowerRightPath" Data="M0,0 L1,1 L1,0 " Grid.Row="2" Fill="{TemplateBinding BorderBrush}" Stretch="Fill" Margin="12,0" Height="12" Width="18" Visibility="Collapsed" HorizontalAlignment="Right" />
                        <Path Name="LowerLeftPath" Data="M0,0 L0,1 L1,0" Grid.Row="2" Fill="{TemplateBinding BorderBrush}" Stretch="Fill" Margin="12,0" Height="12" Width="18" Visibility="Collapsed" HorizontalAlignment="Left" />
                        <Path Name="UpperLeftPath" Data="M0,0 L1,1 L0,1 " Grid.Row="0" Fill="{TemplateBinding BorderBrush}" Stretch="Fill" Margin="12,0" Height="12" Width="18" Visibility="Collapsed" HorizontalAlignment="Left" />
                        <Path Name="UpperRightPath" Data="M0,1 L1,1 L1,0 " Grid.Row="0" Fill="{TemplateBinding BorderBrush}" Stretch="Fill" Margin="12,0" Height="12" Width="18" Visibility="Collapsed" HorizontalAlignment="Right" />
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    <Style TargetType="local:ChatBubbleTextBox">
        <Setter Property="FontFamily" Value="{StaticResource FontFamilySegoeNormal}" />
        <Setter Property="FontSize" Value="{StaticResource DefaultFontSizeMediumLarge}" />
        <Setter Property="Background" Value="{StaticResource DefaultTextBoxBrush}" />
        <Setter Property="Foreground" Value="{StaticResource DefaultTextBoxForegroundBrush}" />
        <Setter Property="BorderBrush" Value="{StaticResource DefaultTextBoxBrush}" />
        <Setter Property="BorderThickness" Value="{StaticResource DefaultBorderThickness}" />
        <Setter Property="Padding" Value="7, 4, 0, 4" />
        <Setter Property="ScrollViewer.HorizontalScrollBarVisibility" Value="Hidden" />
        <Setter Property="ScrollViewer.VerticalScrollBarVisibility" Value="Hidden" />
        <Setter Property="ScrollViewer.IsDeferredScrollingEnabled" Value="False" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="local:ChatBubbleTextBox">
                    <Grid>
                        <VisualStateManager.VisualStateGroups>
                            <VisualStateGroup x:Name="ChatBubbleDirectionStates">
                                <VisualState x:Name="UpperRight">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Visibility" Storyboard.TargetName="UpperRightPath">
                                            <DiscreteObjectKeyFrame KeyTime="0">
                                                <DiscreteObjectKeyFrame.Value>
                                                    <Visibility>Visible</Visibility>
                                                </DiscreteObjectKeyFrame.Value>
                                            </DiscreteObjectKeyFrame>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="UpperLeft">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Visibility" Storyboard.TargetName="UpperLeftPath">
                                            <DiscreteObjectKeyFrame KeyTime="0">
                                                <DiscreteObjectKeyFrame.Value>
                                                    <Visibility>Visible</Visibility>
                                                </DiscreteObjectKeyFrame.Value>
                                            </DiscreteObjectKeyFrame>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="LowerRight">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Visibility" Storyboard.TargetName="LowerRightPath">
                                            <DiscreteObjectKeyFrame KeyTime="0">
                                                <DiscreteObjectKeyFrame.Value>
                                                    <Visibility>Visible</Visibility>
                                                </DiscreteObjectKeyFrame.Value>
                                            </DiscreteObjectKeyFrame>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="LowerLeft">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Visibility" Storyboard.TargetName="LowerLeftPath">
                                            <DiscreteObjectKeyFrame KeyTime="0">
                                                <DiscreteObjectKeyFrame.Value>
                                                    <Visibility>Visible</Visibility>
                                                </DiscreteObjectKeyFrame.Value>
                                            </DiscreteObjectKeyFrame>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                            <VisualStateGroup x:Name="CommonStates">
                                <VisualState x:Name="Disabled">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Background" Storyboard.TargetName="BackgroundElement">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource TextBoxDisabledBackgroundThemeBrush}" />
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="BorderBrush" Storyboard.TargetName="BorderElement">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource TextBoxDisabledBorderThemeBrush}" />
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Foreground" Storyboard.TargetName="ContentElement">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource TextBoxDisabledForegroundThemeBrush}" />
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="Normal">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" To="{StaticResource TextControlBackgroundThemeOpacity}" Storyboard.TargetProperty="Opacity" Storyboard.TargetName="BackgroundElement" />
                                        <DoubleAnimation Duration="0" To="{StaticResource TextControlBorderThemeOpacity}" Storyboard.TargetProperty="Opacity" Storyboard.TargetName="BorderElement" />
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="PointerOver">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" To="{StaticResource TextControlPointerOverBackgroundThemeOpacity}" Storyboard.TargetProperty="Opacity" Storyboard.TargetName="BackgroundElement" />
                                        <DoubleAnimation Duration="0" To="{StaticResource TextControlPointerOverBorderThemeOpacity}" Storyboard.TargetProperty="Opacity" Storyboard.TargetName="BorderElement" />
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="Focused">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="BorderBrush" Storyboard.TargetName="BorderElement">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource DefaultAccentBrush}" />
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                            <VisualStateGroup x:Name="ButtonStates">
                                <VisualState x:Name="ButtonVisible">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Visibility" Storyboard.TargetName="DeleteButton">
                                            <DiscreteObjectKeyFrame KeyTime="0">
                                                <DiscreteObjectKeyFrame.Value>
                                                    <Visibility>Visible</Visibility>
                                                </DiscreteObjectKeyFrame.Value>
                                            </DiscreteObjectKeyFrame>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="ButtonCollapsed" />
                            </VisualStateGroup>
                        </VisualStateManager.VisualStateGroups>
                        <Grid.RowDefinitions>
                            <RowDefinition Height="Auto" />
                            <RowDefinition Height="Auto" />
                            <RowDefinition Height="Auto" />
                        </Grid.RowDefinitions>
                        <Grid Grid.Row="1">
                            <Grid.Resources>
                                <Style x:Name="DeleteButtonStyle" TargetType="Button">
                                    <Setter Property="Template">
                                        <Setter.Value>
                                            <ControlTemplate TargetType="Button">
                                                <Grid>
                                                    <VisualStateManager.VisualStateGroups>
                                                        <VisualStateGroup x:Name="CommonStates">
                                                            <VisualState x:Name="Normal" />
                                                            <VisualState x:Name="PointerOver">
                                                                <Storyboard>
                                                                    <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Background" Storyboard.TargetName="BackgroundElement">
                                                                        <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource TextBoxButtonPointerOverBackgroundThemeBrush}" />
                                                                    </ObjectAnimationUsingKeyFrames>
                                                                    <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="BorderBrush" Storyboard.TargetName="BorderElement">
                                                                        <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource TextBoxButtonPointerOverBorderThemeBrush}" />
                                                                    </ObjectAnimationUsingKeyFrames>
                                                                    <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Foreground" Storyboard.TargetName="GlyphElement">
                                                                        <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource TextBoxButtonPointerOverForegroundThemeBrush}" />
                                                                    </ObjectAnimationUsingKeyFrames>
                                                                </Storyboard>
                                                            </VisualState>
                                                            <VisualState x:Name="Pressed">
                                                                <Storyboard>
                                                                    <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Background" Storyboard.TargetName="BackgroundElement">
                                                                        <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource TextBoxButtonPressedBackgroundThemeBrush}" />
                                                                    </ObjectAnimationUsingKeyFrames>
                                                                    <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="BorderBrush" Storyboard.TargetName="BorderElement">
                                                                        <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource TextBoxButtonPressedBorderThemeBrush}" />
                                                                    </ObjectAnimationUsingKeyFrames>
                                                                    <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Foreground" Storyboard.TargetName="GlyphElement">
                                                                        <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource TextBoxButtonPressedForegroundThemeBrush}" />
                                                                    </ObjectAnimationUsingKeyFrames>
                                                                </Storyboard>
                                                            </VisualState>
                                                            <VisualState x:Name="Disabled">
                                                                <Storyboard>
                                                                    <DoubleAnimation Duration="0" To="0" Storyboard.TargetProperty="Opacity" Storyboard.TargetName="BackgroundElement" />
                                                                    <DoubleAnimation Duration="0" To="0" Storyboard.TargetProperty="Opacity" Storyboard.TargetName="BorderElement" />
                                                                </Storyboard>
                                                            </VisualState>
                                                        </VisualStateGroup>
                                                    </VisualStateManager.VisualStateGroups>
                                                    <Border Name="BorderElement" BorderBrush="{StaticResource TextBoxButtonBorderThemeBrush}" BorderThickness="{TemplateBinding BorderThickness}" />
                                                    <Border Name="BackgroundElement" Background="{StaticResource TextBoxButtonBackgroundThemeBrush}" Margin="{TemplateBinding BorderThickness}">
                                                        <TextBlock Name="GlyphElement" Foreground="{StaticResource TextBoxButtonForegroundThemeBrush}" HorizontalAlignment="Center" Text="" VerticalAlignment="Center" />
                                                    </Border>
                                                </Grid>
                                            </ControlTemplate>
                                        </Setter.Value>
                                    </Setter>
                                </Style>
                            </Grid.Resources>
                            <Grid.ColumnDefinitions>
                                <ColumnDefinition Width="*" />
                                <ColumnDefinition Width="Auto" />
                            </Grid.ColumnDefinitions>
                            <Border Name="BackgroundElement" Background="{TemplateBinding Background}" Margin="{TemplateBinding BorderThickness}" Grid.ColumnSpan="2" />
                            <Border Name="BorderElement" Background="Transparent" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" Grid.ColumnSpan="2" />
                            <TextBlock Opacity="0" Text="{TemplateBinding Text}" Margin="{TemplateBinding BorderThickness}" Padding="{TemplateBinding Padding}" />
                            <ScrollViewer Name="HintContentElement" Foreground="{StaticResource DefaultTextBoxReadOnlyBrush}" Content="{TemplateBinding Hint}" HorizontalScrollMode="{TemplateBinding ScrollViewer.HorizontalScrollMode}" HorizontalScrollBarVisibility="{TemplateBinding ScrollViewer.HorizontalScrollBarVisibility}" IsTabStop="False" IsHorizontalRailEnabled="{TemplateBinding ScrollViewer.IsHorizontalRailEnabled}" IsVerticalRailEnabled="{TemplateBinding ScrollViewer.IsVerticalRailEnabled}" IsDeferredScrollingEnabled="{TemplateBinding ScrollViewer.IsDeferredScrollingEnabled}" Margin="{TemplateBinding BorderThickness}" Padding="{TemplateBinding Padding}" VerticalScrollBarVisibility="{TemplateBinding ScrollViewer.VerticalScrollBarVisibility}" VerticalScrollMode="{TemplateBinding ScrollViewer.VerticalScrollMode}" ZoomMode="Disabled" />
                            <ScrollViewer Name="ContentElement" HorizontalScrollMode="{TemplateBinding ScrollViewer.HorizontalScrollMode}" HorizontalScrollBarVisibility="{TemplateBinding ScrollViewer.HorizontalScrollBarVisibility}" IsTabStop="False" IsHorizontalRailEnabled="{TemplateBinding ScrollViewer.IsHorizontalRailEnabled}" IsVerticalRailEnabled="{TemplateBinding ScrollViewer.IsVerticalRailEnabled}" IsDeferredScrollingEnabled="{TemplateBinding ScrollViewer.IsDeferredScrollingEnabled}" Margin="{TemplateBinding BorderThickness}" Padding="{TemplateBinding Padding}" VerticalScrollBarVisibility="{TemplateBinding ScrollViewer.VerticalScrollBarVisibility}" VerticalScrollMode="{TemplateBinding ScrollViewer.VerticalScrollMode}" ZoomMode="Disabled" />
                            <Button Name="DeleteButton" Style="{StaticResource DeleteButtonStyle}" BorderThickness="{TemplateBinding BorderThickness}" FontSize="{TemplateBinding FontSize}" IsTabStop="False" Visibility="Collapsed" VerticalAlignment="Stretch" Grid.Column="1" />
                        </Grid>
                        <Path Name="LowerRightPath" Data="M0,0 L1,1 L1,0 " Grid.Row="2" Fill="{Binding ElementName=BorderElement, Path=BorderBrush}" Opacity="{Binding ElementName=BorderElement, Path=Opacity}" Stretch="Fill" Margin="12,0" Height="12" Width="18" Visibility="Collapsed" HorizontalAlignment="Right" VerticalAlignment="Top" />
                        <Path Name="LowerLeftPath" Data="M0,0 L0,1 L1,0" Grid.Row="2" Fill="{Binding ElementName=BorderElement, Path=BorderBrush}" Opacity="{Binding ElementName=BorderElement, Path=Opacity}" Stretch="Fill" Margin="12,0" Height="12" Width="18" Visibility="Collapsed" HorizontalAlignment="Left" VerticalAlignment="Top" />
                        <Path Name="UpperLeftPath" Data="M0,0 L1,1 L0,1 " Grid.Row="0" Fill="{Binding ElementName=BorderElement, Path=BorderBrush}" Opacity="{Binding ElementName=BorderElement, Path=Opacity}" Stretch="Fill" Margin="12,0" Height="12" Width="18" Visibility="Collapsed" HorizontalAlignment="Left" VerticalAlignment="Bottom" />
                        <Path Name="UpperRightPath" Data="M0,1 L1,1 L1,0 " Grid.Row="0" Fill="{Binding ElementName=BorderElement, Path=BorderBrush}" Opacity="{Binding ElementName=BorderElement, Path=Opacity}" Stretch="Fill" Margin="12,0" Height="12" Width="18" Visibility="Collapsed" HorizontalAlignment="Right" VerticalAlignment="Bottom" />
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <Style TargetType="local:ColorHexagonPicker">
        <Setter Property="VerticalAlignment" Value="Center" />
        <Setter Property="HorizontalAlignment" Value="Center" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="local:ColorHexagonPicker">
                    <StackPanel>
                        <ContentPresenter Content="{TemplateBinding ColorBody}" />
                        <ContentPresenter Content="{TemplateBinding GreyScaleBody}" />
                    </StackPanel>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    <Style TargetType="local:ImageTile">
        <Setter Property="Background" Value="{StaticResource DefaultAccentBrush}" />
        <Setter Property="Foreground" Value="{StaticResource DefaultForegroundBrush}" />
        <Setter Property="FontFamily" Value="{StaticResource FontFamilySegoeSemiBold}" />
        <Setter Property="FontSize" Value="{StaticResource DefaultFontSizeNormal}" />
        <Setter Property="Margin" Value="10" />
        <Setter Property="Padding" Value="10,0" />
        <Setter Property="VerticalAlignment" Value="Top" />
        <Setter Property="HorizontalAlignment" Value="Right" />
        <Setter Property="MinWidth" Value="36" />
        <Setter Property="MinHeight" Value="36" />
        <Setter Property="Width" Value="{StaticResource DefaultTileSize}" />
        <Setter Property="Height" Value="{StaticResource DefaultTileSize}" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="local:ImageTile">
                    <Grid Width="{TemplateBinding Width}" Height="{TemplateBinding Height}" Background="{TemplateBinding Background}">
                        <Grid x:Name="ImageContainer" />
                        <ContentControl Content="{TemplateBinding Content}" FontSize="{TemplateBinding FontSize}" FontFamily="{TemplateBinding FontFamily}" FontWeight="{TemplateBinding FontWeight}" />
                        <ContentControl Content="{TemplateBinding Label}" FontSize="{TemplateBinding FontSize}" FontFamily="{TemplateBinding FontFamily}" FontWeight="{TemplateBinding FontWeight}" VerticalAlignment="Bottom" HorizontalAlignment="Left" Padding="10, 0, 0, 10" Margin="0, 0, 0, -5" />
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    
    <Style TargetType="local:SuperImage">
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="local:SuperImage">
                    <Grid>
                        <Border x:Name="PlaceholderBorder" Opacity="{TemplateBinding PlaceholderOpacity}" Background="{TemplateBinding PlaceholderBackground}">
                            <Image x:Name="PlaceholderImage" Source="{TemplateBinding PlaceholderImageSource}" Stretch="{TemplateBinding PlaceholderImageStretch}" />
                        </Border>
                        <Image x:Name="PrimaryImage" Source="{TemplateBinding Source}" Stretch="{TemplateBinding Stretch}" />
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    <Style TargetType="local:Tile">
        <Setter Property="Background" Value="{StaticResource DefaultAccentBrush}" />
        <Setter Property="Foreground" Value="{StaticResource DefaultForegroundBrush}" />
        <Setter Property="FontSize" Value="{StaticResource DefaultFontSizeNormal}" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="local:Tile">
                    <Grid Name="root" Background="{TemplateBinding Background}">
                        <VisualStateManager.VisualStateGroups>
                            <VisualStateGroup x:Name="CommonStates">
                                <VisualState x:Name="Normal" />
                                <VisualState x:Name="MouseOver" />
                                <VisualState x:Name="Pressed" />
                                <VisualState x:Name="PointerOver" />
                                <VisualState x:Name="Disabled">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Foreground" Storyboard.TargetName="titleText">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource DefaultContrastDisabledBrush}" />
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Foreground" Storyboard.TargetName="contentContainer">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource DefaultContrastDisabledBrush}" />
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Background" Storyboard.TargetName="root">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource DefaultDisabledBrush}" />
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                        </VisualStateManager.VisualStateGroups>
                        <ContentControl Name="contentContainer" HorizontalContentAlignment="Stretch" VerticalContentAlignment="Stretch" Content="{TemplateBinding Content}" />
                        <!-- 
							Label is an object but TextWrapping is TextBlock Only
							... this could blow up 
						-->
                        <TextBlock Name="titleText" TextWrapping="{TemplateBinding TextWrapping}" FontSize="{TemplateBinding FontSize}" FontFamily="{TemplateBinding FontFamily}" VerticalAlignment="Bottom" Padding="12, 0" Margin="0, 0, 0, 7" Text="{TemplateBinding Label}" />
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    <Style TargetType="local:TileNotification">
        <Setter Property="Background" Value="{StaticResource DefaultChromeBrush}" />
        <Setter Property="Foreground" Value="{StaticResource DefaultForegroundBrush}" />
        <Setter Property="FontWeight" Value="SemiBold" />
        <Setter Property="FontSize" Value="{StaticResource DefaultFontSizeNormal}" />
        <Setter Property="Margin" Value="5" />
        <Setter Property="Padding" Value="9, 0, 9, -1" />
        <Setter Property="VerticalAlignment" Value="Top" />
        <Setter Property="HorizontalAlignment" Value="Right" />
        <Setter Property="MinWidth" Value="28" />
        <Setter Property="MinHeight" Value="28" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="local:TileNotification">
                    <Grid>
                        <Rectangle Fill="{TemplateBinding Background}" RadiusX="14" RadiusY="14" />
                        <ContentControl Margin="{TemplateBinding Padding}" Content="{TemplateBinding Content}" VerticalAlignment="Center" HorizontalAlignment="Center" />
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    <Style TargetType="local:PasswordInputPrompt">
        <Setter Property="FontFamily" Value="{StaticResource FontFamilySegoeNormal}" />
        <Setter Property="FontSize" Value="{StaticResource DefaultFontSizeNormal}" />
        <Setter Property="Foreground" Value="{StaticResource DefaultForegroundBrush}" />
        <Setter Property="Background" Value="{StaticResource DefaultChromeBrush}" />
        <Setter Property="Overlay" Value="{StaticResource DefaultSemiTransparentBrush}" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="local:PasswordInputPrompt">
                    <Grid>
                        <Border VerticalAlignment="Top" Margin="10" Background="{TemplateBinding Background}" BorderThickness="1" BorderBrush="{StaticResource DefaultForegroundBrush}">
                            <StackPanel Margin="10">
                                <TextBlock Text="{TemplateBinding Title}" Margin="0, -10, -25, 0" TextWrapping="Wrap" FontFamily="{StaticResource FontFamilySegoeSemiLight}" FontSize="{StaticResource DefaultFontSizeLarge}" />
                                <TextBlock Text="{TemplateBinding Message}" TextWrapping="{TemplateBinding MessageTextWrapping}" />
                                <TextBox Name="inputBox" InputScope="{TemplateBinding InputScope}" Margin="-12, 0" />
                                <StackPanel Name="actionButtonArea" Orientation="Horizontal" HorizontalAlignment="Center" Margin="0, 0, 0, -12" />
                            </StackPanel>
                        </Border>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    <Style TargetType="local:ToastPrompt">
        <Setter Property="FontFamily" Value="{StaticResource FontFamilySegoeNormal}" />
        <Setter Property="FontSize" Value="{StaticResource DefaultFontSizeSmall}" />
        <Setter Property="Foreground" Value="White" />
        <Setter Property="Background" Value="{StaticResource DefaultAccentBrush}" />
        <Setter Property="VerticalAlignment" Value="Top" />
        <Setter Property="Overlay" Value="Transparent" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="local:ToastPrompt">
                    <Grid VerticalAlignment="{TemplateBinding VerticalAlignment}" Background="{TemplateBinding Background}">
                        <StackPanel VerticalAlignment="Bottom" Margin="24, 32, 16, 5" Orientation="{TemplateBinding TextOrientation}">
                            <StackPanel Margin="0,0,16,0" VerticalAlignment="Bottom" Orientation="Horizontal">
                                <Image Margin="0,0,16,0" Visibility="Collapsed" Name="ToastImage" VerticalAlignment="Bottom" Width="{TemplateBinding ImageWidth}" Height="{TemplateBinding ImageHeight}" Source="{TemplateBinding ImageSource}" Stretch="{TemplateBinding Stretch}" />
                                <TextBlock Text="{TemplateBinding Title}" FontWeight="Bold" VerticalAlignment="Center" Margin="0" Padding="0" />
                            </StackPanel>
                            <TextBlock Text="{TemplateBinding Message}" Margin="0" Padding="0" TextWrapping="{TemplateBinding TextWrapping}" VerticalAlignment="Center" />
                        </StackPanel>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    <Style TargetType="local:AboutPrompt">
        <Setter Property="Overlay" Value="{StaticResource DefaultSemiTransparentBrush}" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="local:AboutPrompt">
                    <Grid>
                        <Rectangle Fill="Transparent" />
                        <Border VerticalAlignment="Center" Background="{StaticResource DefaultChromeBrush}" BorderThickness="1" BorderBrush="{StaticResource DefaultForegroundBrush}">
                            <Grid>
                                <ContentPresenter Content="{TemplateBinding WaterMark}" />
                                <Grid Margin="10">
                                    <Grid.RowDefinitions>
                                        <RowDefinition Height="Auto" />
                                        <RowDefinition Height="*" />
                                        <RowDefinition Height="Auto" />
                                        <RowDefinition Height="Auto" />
                                    </Grid.RowDefinitions>
                                    <TextBlock Grid.Row="0" VerticalAlignment="Top" Text="{TemplateBinding Title}" Margin="0,-10,-25,0" FontSize="56" TextWrapping="Wrap" FontFamily="Segoe WP Light" />
                                    <ScrollViewer Grid.Row="1" Margin="0,0,0,10">
                                        <ContentPresenter Content="{TemplateBinding Body}" />
                                    </ScrollViewer>
                                    <ContentPresenter Grid.Row="2" Content="{TemplateBinding Footer}" />
                                    <StackPanel Name="actionButtonArea" Orientation="Horizontal" HorizontalAlignment="Center" VerticalAlignment="Bottom" Grid.Row="3" />
                                    <TextBlock Grid.Row="3" Margin="0,0,10,10" VerticalAlignment="Bottom" HorizontalAlignment="Right" Text="{TemplateBinding VersionNumber}" FontFamily="Segoe WP Light" />
                                </Grid>
                            </Grid>
                        </Border>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    <Style TargetType="local:AboutPromptItem">
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="local:AboutPromptItem">
                    <Grid Margin="0,11,0,0">
                        <Grid.Resources>
                            <Style x:Key="rightSide" TargetType="TextBlock">
                                <Setter Property="Grid.Column" Value="1" />
                                <Setter Property="Margin" Value="10,0,0,5" />
                            </Style>
                            <Style x:Key="leftSide" TargetType="TextBlock">
                                <Setter Property="HorizontalAlignment" Value="Right" />
                                <Setter Property="VerticalAlignment" Value="top" />
                                <Setter Property="Grid.Column" Value="0" />
                                <Setter Property="FontWeight" Value="Bold" />
                            </Style>
                        </Grid.Resources>
                        <Grid.ColumnDefinitions>
                            <ColumnDefinition Width="80" />
                            <ColumnDefinition />
                        </Grid.ColumnDefinitions>
                        <TextBlock Style="{StaticResource leftSide}" Text="{TemplateBinding Role}" />
                        <StackPanel Grid.Column="1">
                            <TextBlock Name="author" Style="{StaticResource rightSide}" Text="{TemplateBinding AuthorName}" Visibility="Collapsed" />
                            <TextBlock Name="website" Style="{StaticResource rightSide}" Text="{TemplateBinding WebSiteDisplay}" Visibility="Collapsed" />
                            <TextBlock Name="emailAddress" Style="{StaticResource rightSide}" Text="{TemplateBinding EmailAddress}" Visibility="Collapsed" />
                        </StackPanel>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    <Style TargetType="local:MessagePrompt">
        <Setter Property="FontFamily" Value="{StaticResource FontFamilySegoeNormal}" />
        <Setter Property="FontSize" Value="{StaticResource DefaultFontSizeNormal}" />
        <Setter Property="Foreground" Value="{StaticResource DefaultForegroundBrush}" />
        <Setter Property="Background" Value="{StaticResource DefaultChromeBrush}" />
        <Setter Property="Overlay" Value="{StaticResource DefaultSemiTransparentBrush}" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="local:MessagePrompt">
                    <Grid>
                        <Border VerticalAlignment="Top" Margin="10" Background="{TemplateBinding Background}" BorderThickness="1" BorderBrush="{StaticResource DefaultForegroundBrush}">
                            <StackPanel Margin="10">
                                <TextBlock Text="{TemplateBinding Title}" Margin="0, -10, -25, 0" TextWrapping="Wrap" FontFamily="{StaticResource FontFamilySegoeSemiLight}" FontSize="{StaticResource DefaultFontSizeLarge}" />
                                <ContentPresenter Content="{TemplateBinding Body}" Margin="0, 10" />
                                <StackPanel Margin="0, 0, 0, -12" Name="actionButtonArea" Orientation="Horizontal" HorizontalAlignment="Center" />
                            </StackPanel>
                        </Border>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    <Style TargetType="local:InputPrompt">
        <Setter Property="FontFamily" Value="{StaticResource FontFamilySegoeNormal}" />
        <Setter Property="FontSize" Value="{StaticResource DefaultFontSizeNormal}" />
        <Setter Property="Foreground" Value="{StaticResource DefaultForegroundBrush}" />
        <Setter Property="Background" Value="{StaticResource DefaultChromeBrush}" />
        <Setter Property="Overlay" Value="{StaticResource DefaultSemiTransparentBrush}" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="local:InputPrompt">
                    <Grid>
                        <Border VerticalAlignment="Top" Margin="10" Background="{TemplateBinding Background}" BorderThickness="1" BorderBrush="{StaticResource DefaultForegroundBrush}">
                            <StackPanel Margin="10">
                                <TextBlock Text="{TemplateBinding Title}" Margin="0, -10, -25, 0" TextWrapping="Wrap" FontFamily="{StaticResource FontFamilySegoeSemiLight}" FontSize="{StaticResource DefaultFontSizeLarge}" />
                                <TextBlock Text="{TemplateBinding Message}" TextWrapping="{TemplateBinding MessageTextWrapping}" />
                                <TextBox Name="inputBox" InputScope="{TemplateBinding InputScope}" Text="{TemplateBinding Value}" Margin="-12, 0" />
                                <StackPanel Name="actionButtonArea" Orientation="Horizontal" HorizontalAlignment="Center" Margin="0, 0, 0, -12" />
                            </StackPanel>
                        </Border>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    <Style TargetType="local:SuperSlider">
        <Setter Property="Background" Value="{StaticResource DefaultChromeBrush}" />
        <Setter Property="Foreground" Value="{StaticResource DefaultAccentBrush}" />
        <Setter Property="Padding" Value="0, 3, 0, 36" />

        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="local:SuperSlider">
                    <Grid Name="Body">
                        <Grid.RowDefinitions>
                            <RowDefinition Height="Auto" />
                            <RowDefinition />
                        </Grid.RowDefinitions>
                        <VisualStateManager.VisualStateGroups>
                            <VisualStateGroup x:Name="CommonStates">
                                <VisualState x:Name="Normal" />
                                <VisualState x:Name="Disabled">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames
													Storyboard.TargetProperty="Fill" 
													Storyboard.TargetName="ProgressRectangle">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource DefaultDisabledBrush}"/>

                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames
													Storyboard.TargetProperty="Fill" 
													Storyboard.TargetName="BackgroundRectangle">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource DefaultChromeBrush}"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                        </VisualStateManager.VisualStateGroups>

                        <Grid Grid.Row="1">
                            <Border Margin="{TemplateBinding Padding}">
                                <Grid Name="BarBody">
                                    <Rectangle 
										Grid.Row="1"
										Name="BackgroundRectangle"
										Fill="{TemplateBinding Background}" />
                                    <Rectangle 
										Grid.Row="1"
										Name="ProgressRectangle"
										Fill="{TemplateBinding Foreground}" />

                                    <ContentPresenter
										Grid.Row="1"
										Content="{TemplateBinding Thumb}" />
                                </Grid>
                            </Border>
                        </Grid>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
</ResourceDictionary>
